<?php
declare (strict_types=1);

use think\facade\Route;

/**
 * 专项练习管理
 */
Route::group('admin/module/<module_id>/special/<special_id>/', function () {
    // 列表
    Route::get('list', 'index');
    // 题目选择面板
    Route::get('choose/options', 'getChooseOptions');
    // 获取题目列表
    Route::get('choose/list', 'getChooseList');
    // 新增试题
    Route::post('create', 'create');
    // 删除试卷
    Route::delete('<id>/delete', 'delete')->pattern(['id' => '\d+']); // 删除
    // 批量删除
    Route::delete('deletes/<ids>', 'deletes')->pattern(['ids' => '[\d,]+']);// 批量删除
})->prefix('\app\exam\service\admin\ModuleSpecialTopic@')
    ->middleware('adminRoute')
    ->pattern(['module_id' => '\d+', 'special_id' => '\d+']);
